package com.hb.gp.util.command;

import java.util.List;

import com.hb.gp.util.MsgGenUtil;
import com.hb.gp.util.tools.GP_GetMac;

public class APDU_SetStatus {
	public static String setStatus(String tcode, String aid, String p1,
			String p2, List<String> sessionKeys, String icv) {
		// String pbCardKeyMacSk = sessionKeys.get(1);
		StringBuffer sb = new StringBuffer();
		sb.append("84F0");
		sb.append(p1);
		sb.append(p2);
		sb.append(MsgGenUtil.Int2Bytes1(aid.length() / 2));
		sb.append(aid);
		String apdu = GP_GetMac.getIMac(sb.toString(), sessionKeys.get(1), icv,
				true);
		return apdu;
	}
}
